#!/usr/bin/env python
# vim:fileencoding=utf-8

from calibre.web.feeds.news import BasicNewsRecipe


class ViknaSTB(BasicNewsRecipe):
    title = '\u0412\u0456\u043A\u043D\u0430-\u043D\u043E\u0432\u0438\u043D\u0438'
    __author__ = 'bugmen00t'
    description = '\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0430 \u0456\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0456\u0439\u043D\u0430 \u043F\u0440\u043E\u0433\u0440\u0430\u043C\u0430 \u0442\u0435\u043B\u0435\u043A\u0430\u043D\u0430\u043B\u0443 \u00AB\u0421\u0422\u0411\u00BB.'  # noqa
    publisher = '\u0422\u041E\u0412 \u201C\u0421\u041B\u041C \u041D\u043E\u0432\u0438\u043D\u0438\u201D'
    category = 'newspaper'
    cover_url = u'https://yt3.ggpht.com/QZxhLPDcqhjMitCDPWbzk-Zs-ILbGo3ww1iuV9SIE1k0iqjoOIctT2d4BdyEsSAR6yWsbKbGWg=s900-c-k-c0x00ffffff-no-rj'
    language = 'uk'
    no_stylesheets = False
    remove_javascript = False
    auto_cleanup = False
    remove_empty_feeds = True
    oldest_article = 3
    max_articles_per_feed = 20

    remove_tags_before = dict(name='h1')

    remove_tags_after = dict(name='div', attrs={'class': 'content-wrapper'})

    remove_tags = [
        dict(name='div', attrs={'class': 'share-content-wrapper flex-wrapper'}),
        dict(name='div', attrs={'class': 'sticky-wrapper'}),
        dict(name='div', attrs={'class': 'promo-wrapper'}),
        dict(name='div', attrs={'class': 'mn-wrapper'}),
        dict(name='div', attrs={'class': 'news-tags border-btm-grey'})
    ]

    feeds = [('\u0412\u0456\u043A\u043D\u0430', 'https://vikna.tv/feed/')]
